package com.dycx.common.rabbitmq;

import lombok.Data;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Configuration;

/**
 * 配置类
 *
 * @author LiuHui
 * @since 2023-05-15
 **/
@Data
@Configuration
public class RabbitMqConfig {

    @Value("${spring.rabbitmq.host}")
    private String host;

    @Value("${spring.rabbitmq.port}")
    private int port;

    @Value("${spring.rabbitmq.username}")
    private String username;

    @Value("${spring.rabbitmq.password}")
    private String password;

    @Value("${spring.rabbitmq.virtual-host}")
    private String virtualHost;


    //************支付************
    /**
     * 交换机
     */
    @Value("payment.exchange")
    private String paymentExchange;

    /**
     * 队列
     */
    @Value("payment.create.queue")
    private String paymentCreateQueue;

    /**
     * 路由
     */
    @Value("payment.create.routing")
    private String paymentCreateRouting;

    //************消息************
    /**
     * 交换机
     */
    @Value("message.exchange")
    private String messageExchange;

    /**
     * 队列
     */
    @Value("message.create.queue")
    private String messageCreateQueue;

    /**
     * 路由
     */
    @Value("message.create.routing")
    private String messageCreateRouting;
}
